<template>
	<view class="content">
		
		<view class="lis">
			<view v-for="(item,index) in orderData" :key="index" class="list">
				<view class="liTop">
					<view class="fl fs20 C6">
						订单号：{{item.order_sn}}
					</view>
					<view class="fr fs22 Cfe0000 bold">
						{{(item.type==1?"-":"+")+item.commission}}
					</view>
				</view>				
				<view style="clear: both;" class="liBottom">
					<view class="fl fs20 C6">
						<!-- {{item.order_type}} -->
						下单时间：
					</view>
					<view class="fr fs20 C999">
						{{item.add_time |formaDate}}
						<!-- ('yyyy-mm-dd') -->
					</view>
				</view>
				<view style="clear: both;" class="liBottom">
					<view class="fl fs20 C6">
						佣金描述：
					</view>
					<view class="fr fs20 C999">
					</view>
				</view>
				<view >
					{{item.log_desc}}
				</view>
				
			</view>
		</view>
		<!-- <view v-if="orderData.length > 0" style="" @click="tixian()" class="center tix">提现</view> -->
		<view v-if="orderData.length<=0" class="None">
			<image style="width: 100%;" :src="`${picUrl}/InfoNull.png`" mode="widthFix"></image>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				curpage:1,
				orderData:[{
						order_sn:'',//订单号
						add_time:'',//下单时间
						log_desc:''//详情
					}],
				member_id:[],
			}
		},
		
		onLoad() {
			this.getZixunData()
		},
		onReachBottom(){
			if(this.curpage){
				this.getZixunData(true)
			}else{
				uni.showToast({
					title:'到底了哦~~',
					icon:'none'
				})
			}
		},
		methods: {
			tixian(){
				uni.navigateTo({
					url:"/member/wallet/withdrawal"
				})
			},
			getZixunData(state){
				let that = this;
				this.$util.request({
					// index.php?act=predeposit&op=freeze_predeposit
					url: '/mobile/index.php?act=distribution&op=commission_log_list',
					method: 'get',
					data: {curpage:this.curpage},
				}).then(function(res) {
					if(state){
						that.orderData=that.orderData.concat(res.datas.log_list)  
					}else{
						that.orderData=res.datas.log_list
					}
					if(res.datas.page_info.hasmore){
						that.curpage++
					}else{
						that.curpage=res.datas.page_info.hasmore
					}
					
				})
			}
			

		}
	}
</script>

<style>
	.None{
		font-size: 30rpx;
		font-weight: bold;
		text-align: center;
		/* margin: 40rpx 0; */
		}
	.lh20{
		line-height: 20upx;
		height: 20upx;
	}
	.lh25{
		line-height: 25upx;
	}
	.lh30{
		line-height: 30upx;
	}
	.lh35{
		line-height: 35upx;
	}
	.lh40{
		line-height: 40upx;
	}
	.lh45{
		line-height: 45upx;
	}
	.lh50{
		line-height: 50upx;
	}
	.lh80{
		line-height: 80upx;
	}
	.C000{
		color: #000000;
	}
	.Ce13d97{
		color: #ff4300;
	}
	.tix{
		background-color: #ff4300;
		padding:3upx 25upx;
		border-radius: 10upx;
		color: #FFFFFF;
		width: 150upx;
		margin: 20upx auto;
		font-weight: bold;
	}
	.Cfe0000{
		color: #ff4300;
		
	}
	.Cc06{
		color: #ff4300;
	}
	.mt55mb30{
		margin-top: 55upx;
		margin-bottom: 30upx;
	}
	.Cfff{
		color: #FFFFFF;
	}
	
	.flex{		
		display: flex;
		flex-direction: row;
		justify-content: space-between;
		align-content: space-between;
	}
	.paddingL20{
		padding-left: 20upx;
	}
	.C999{
		color:#999 ;
	}
	.Cff0101{
		color:#ff0101 ;
	}
	.Cc00251{
		color: #c00251;
	}
	.strick{
		text-decoration: line-through;
	}
	.Cfe0000{
		color: #ff4300;
	}
	.line1{
		width: 430upx;
	}
	.hide{
		display: none;
	}
	.marginB20{
		margin-bottom: 20upx;
	}
	
	.twoline{
	   overflow : hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-line-clamp: 2;
		-webkit-box-orient: vertical;
	}
	.pl20{
		padding-left: 20upx;
	}
	.positionT{
		position: relative;
		top: 50upx;
	}
	.paddingB15{
		padding-bottom: 15upx;
	}
	.borderB{
		border-bottom: 1px solid #f4f4f6;
	}
	.borderT{
		border-top: 1px solid #f4f4f6;
	}
	.gl{
		position: absolute;
		right: 30upx;
	}
	.pr30{
		padding-right: 30upx;
	}
	.C333{
		color: #333333;
	}
	.C666{
		color: #666666;
	}
	.Cf00{
		color: #ff0000;
	}
	
	.bold{
		font-weight: bold;
	}
	.C1d1d1d{
		color:#1d1d1d ;
	}
	.fl{
		float: left;
	}
	.fr{
		float: right;
	}
	.tac{
		text-align: center;
	}
	.Ce5258e{
		color: #e5258e;
	}
	.Cccc{
		color: #CCCCCC;
	}
	uni-page-body {
		background-color: #FFFFFF;
		color: rgb(102, 102, 102);
	}		
	.fs30{
		/* font-size: 30upx */
		font-size: 45upx
	}
	.fs26{
		font-size:39upx
		/* font-size: 26upx */
	}
	.fs12{
		font-size: 18upx
		/* font-size: 12upx */
	}
	.fs16{
		font-size: 24upx
		/* font-size: 16upx */
	}
	.fs14{
		font-size: 21upx
		/* font-size: 14upx */
	}
	.fs15{
		font-size: 22.5upx
		/* font-size: 15upx */
	}
	.fs27{
		font-size: 40.5upx
		/* font-size: 27upx */
	}
	.fs18{
		font-size: 27upx
		/* font-size: 18upx */
	}
	.fs28{
		font-size: 42upx
		/* font-size: 28upx */
	}
	.fs10{
		font-size: 15upx
		/* font-size: 10upx */
	}
	.fs30{
		font-size: 45upx
		/* font-size: 28upx */
	}
	.fs24{
		font-size: 36upx
		/* font-size: 24upx */
	}
	.fs20{
		font-size:30upx
		/* font-size: 20upx */
	}
	.fs22{
		font-size:33upx
		/* font-size: 22upx */
	}
	.fs21{
		font-size: 31.5upx
		/* font-size: 21upx */
	}
	view{
		box-sizing: border-box;
	}
	.content{
		min-height: 100vh;
		box-sizing: border-box;
		background-color: #FFFFFF;
		padding: 0 26upx;
	}
	.zichan{
		display: flex;
		flex-direction: row;
		justify-content: space-around;
		align-content: space-around;
	}
	.lis{
		
	}
	.list{
		padding-top: 10upx;
		/* height: 140upx; */
		border-bottom: 1upx solid #f4f4f4;
		margin-bottom: 10rpx;
		display: flex;
		flex-direction: column;
	}


</style>
